import json
import os


def read_product_data():
    filename = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
    product_data_path = os.path.join(filename, "data", "product.json")
    login_data_path = os.path.join(filename, "data", "back_login.json")
    with open(product_data_path, "r", encoding="utf-8") as f:
        product_data = json.load(f)
    with open(login_data_path, "r", encoding="utf-8") as f:
        login_data = json.load(f)
    return product_data, login_data
